<bc:ExGRID x:Class="SLS.Presentation.GridMiniGOODSTYPE"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
             xmlns:exc="clr-namespace:SLS.Controls;assembly=CLSControls" 
             xmlns:bc="clr-namespace:SLS.Base;assembly=CLSBase"
             x:Name="Container" 
             ToolTip="{Binding DisplayName}"
             xmlns:meffed="http:\\www.codeplex.com\MEFedMVVM"            
            >
    <bc:ExGRID.Resources>
        <CollectionViewSource   x:Key="vwBaseTable"
                                Source="{Binding Path=ViewDataSet.SetEnv.GOODSTYPE}" />
    </bc:ExGRID.Resources>
    <StackPanel>
    <WrapPanel>
        <CheckBox Name="IsCheckDataQuality"
        IsChecked="False">CheckDataQuality</CheckBox>
        <Button Name="btnEditRecord"
                Width="Auto"
                Height="Auto"
                VerticalAlignment="Stretch"
                Click="btnEdit_Click">Edit</Button>
        <Button Name="btnEditProcessingRecord"
                Width="Auto"
                Height="Auto"
                VerticalAlignment="Stretch"
                Click="btnEditProcessingRecord_Click">ALL</Button>
     </WrapPanel>
    <WrapPanel>
        <exc:NMICD Name="NMICD"/>
    </WrapPanel>
    <exc:FilteringDataGrid 
          Name="MainGridData"
          ItemsSource="{Binding Source={StaticResource ResourceKey=vwBaseTable}}"
          AutoGenerateColumns="False"
          IsSynchronizedWithCurrentItem="True"
          SelectionChanged="ItemsControls_SelectionChanged"
          SelectionMode="Extended"
          Height="Auto"
          ColumnWidth="SizeToHeader"
          SelectionUnit="FullRow">
        <DataGrid.Columns>
                <DataGridTextColumn x:Name="SM"
                                    Binding="{Binding Path=SM}"
                                    Header="SM"
                                    Width="SizeToHeader" />
                <DataGridTextColumn x:Name="GTPRE"
                                    Binding="{Binding Path=GTPRE}"
                                    Header="GTPRE"
                                    Width="SizeToHeader" />
                <DataGridTextColumn x:Name="KREAL"
                                    Binding="{Binding Path=KREAL}"
                                    Header="KREAL"
                                    Width="SizeToHeader" />
                <DataGridTextColumn x:Name="LDES"
                                    Binding="{Binding Path=LDES}"
                                    Header="LDES"
                                    Width="SizeToHeader" />
                <DataGridTextColumn x:Name="SDES"
                                    Binding="{Binding Path=SDES}"
                                    Header="SDES"
                                    Width="SizeToHeader" />
                <DataGridTextColumn x:Name="POS"
                                    Binding="{Binding Path=POS}"
                                    Header="POS"
                                    Width="SizeToHeader" />
                <DataGridTextColumn x:Name="LPOS"
                                    Binding="{Binding Path=LPOS}"
                                    Header="LPOS"
                                    Width="SizeToHeader" />
                <DataGridTextColumn x:Name="FUSER"
                                    Binding="{Binding Path=FUSER}"
                                    Header="FUSER"
                                    Width="SizeToHeader" />
                <DataGridTextColumn x:Name="FDATE"
                                    Binding="{Binding Path=FDATE}"
                                    Header="FDATE"
                                    Width="SizeToHeader" />
                <DataGridTextColumn x:Name="LUSER"
                                    Binding="{Binding Path=LUSER}"
                                    Header="LUSER"
                                    Width="SizeToHeader" />
                <DataGridTextColumn x:Name="LDATE"
                                    Binding="{Binding Path=LDATE}"
                                    Header="LDATE"
                                    Width="SizeToHeader" />
                <DataGridTextColumn x:Name="UID"
                                    Binding="{Binding Path=UID}"
                                    Header="UID"
                                    Width="SizeToHeader" />
            </DataGrid.Columns>
          </exc:FilteringDataGrid>  
      </StackPanel>
</bc:ExGRID> 